
no = 2
yes = 4

ret = no

m = 1<<2 #yes

flag = ret & m

print("yes?",flag)

m = 1<<1 #yes

flag = ret & m

print("no?",flag,8-2>>1,int('0b111',base=2))

import re

reobj = re.compile(r"\[.+?\]")
#reobj = re.compile("#\d+")
s = "你好[龙魂]#10哈哈"
mobj = reobj.search(s)
print("mobj",mobj)

temStr = "E:/H5Game/Public/FairyGUI/assets/GuildHome/extension/GuildTaskItem.xml"
pathArr = temStr.split("/")

print("pathArr",pathArr)
if "assets" in pathArr:
    idx = pathArr.index("assets")
    if idx+1<len(pathArr):
        packName = pathArr[idx+1]
        print("packName",packName)
